<?php

//  
class qiyekuModule extends Model
{
    public function __construct()
    {
        parent::__construct("qiyeku");
    }

    /**
     * 模糊查询
     * @date: 2019年6月17日 下午6:49:31
     * @param: variable
     * @return:
     * @author: 龚华尧
     */
    public function getlistByqiyemingcheng($qiyemingcheng, $page, $number,$whereStr = "")
    {
        $list = $this
            ->where("entname like '%{$qiyemingcheng}%' and enttype<>'个体工商户' and enttype<>'undefined'")
            ->limit(($page - 1) * $number, $number)
            ->orderBy(" convert(entname using gbk) asc")
            ->all();
        $re_list["data"] = $list;
        $re_list["count"] = count($this->where($whereStr)->all());
        return $re_list;
    }

}